<template>
	<view>
		hello !!
	</view>
</template>

<script>
	import {
		doGet,
		doSave,
		doDelete
	} from "@/utils/offline/sqlite/index.js";
	//巡检的所有接口
	import * as XUNJIAN from '@/api/engineeringMaintenance/engineeringMaintenance.js'
	import {
		pmProcessReportGetDetail
	} from '@/api/comprehensive/comprehensive.js';
	import {
		getPicture
	} from '@/api/doc.js' //获取图片	
	import { DB } from "@/utils/offline/sqlite/dbinit.js";
	export default {
		data() {
			return {
				sqlite: null,
				DB: null,
			}
		},
		mounted() {
			this.test();
		},
		methods: {
			async test() {

				// 查看所有表
				console.log(await DB.getDataBaseTables());
				// await this.DB.deleteTable("images");
				await DB.deleteTable("diseases");
				// await this.DB.clearTable("diseases");
				let resq_params = {
					currPage: 1,
					pageSize: 10000,
					params: {
						lineId: "120",
						lineName: "上海轨道交通10号线",
						lineSiteSectionId: "266",
						lineSiteSectionName: " 航中路站- 紫藤路站上行",
						lineSiteSectionType: "qj",
						mileage: "SK",
						projectId: 8,
						type: "inspect"
					}
				}
				// this.$set(resq_params.params, 'type', 'inspect')
				const result1 = await XUNJIAN.diseaseOrderGetList(resq_params)

				await doSave(XUNJIAN.diseaseOrderSave, test1)
				doGet(XUNJIAN.diseaseOrderGetList, {}).then(res => {
					console.log(res, '0000000000000');
				})
			},
		}
	}
</script>

<style>

</style>
